package com.wennimei.controllers.qa;

import org.springframework.beans.factory.annotation.Autowired;

import com.wennimei.service.AAService;

import net.paoding.rose.web.annotation.Param;
import net.paoding.rose.web.annotation.Path;
import net.paoding.rose.web.annotation.rest.Get;

@Path("")
public class QAController {

    @Autowired
    private AAService aaService;

    @Get("ask")
    public String getAnswer(@Param("q") String question) {
        return "@" + this.aaService.getAnswer(question);
    }

    @Get("doIndex")
    public String doIndex(@Param("x") Integer x) {

        return "@success";
    }
}
